home *** CD-ROM | disk | FTP | other *** search
- /* Print either even or odd pages */
-
- options results
- shell
- address HISPEED.1
-
- SET REQUESTER ON
-
- SET ASK "This macro will print either even or odd pages.|Proceed ?"
-
- if RESULT = 1 then
-
- do
- QUERY JOBS /* anything to print ? */
-
- if RESULT = 0 then
- REQUESTFILE /* no, ask for files */
-
- QUERY JOBS /* anything to print now ? */
-
- if (RESULT ~= 0) then /* let's go ... */
-
- do
-
- QUERY PORT /* remember current output port */
- oldport = RESULT /* for clean exit */
-
- QUERY OUTFILE /* remember current output file */
- oldfile = RESULT /* for the same reason */
-
- set PORT FILE /* set port/file to known state */
- set OUTFILE 'T:PCL'
-
- PRINT /* create output (even/odd) */
-
- do until (choice = 'Q')
-
- say ' '
- say ' Options: '
- say ' -----------------------------------------'
- say ' [e] even pages '
- say ' [o] odd pages '
- say ' [q] quit '
- say ' '
- say ' Note: even pages should be printed first.'
- say ''
-
- pull choice
-
- shell
-
- if (choice = 'E') then do
-
- say ''
- say ' printing even pages ... please wait'
-
- if (oldport = 'SER:') then
- copy 'T:PCL_pass1 SER:'
- else
- copy 'T:PCL_pass1 PAR:'
- end
-
- if (choice = 'O') then do
-
- say ''
- say ' printing odd pages ... please wait'
-
- if (oldport = 'SER:') then
- copy 'T:PCL_pass2 SER:'
- else
- copy 'T:PCL_pass2 PAR:'
- end
-
- address HISPEED.1
-
- end
-
- set PORT oldport /* restore user's preferences */
- set OUTFILE oldfile /* restore user's preferences */
-
- say ''
- say ' (done - please close window)'
-
- end
- end
-